#ifndef _SDK_COMMON_H_
#define _SDK_COMMON_H_




typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
//typedef char int8_t;
typedef short int16_t;
typedef int int32_t;


#define SOCKET_SEND_BUFFER_LENGTH_MAX 1000
#define ROTATE_LEFT(x,s,n) ((x)<<(n))|((x)>>((s)-(n)))
#define ROTATE_RIGHT(x,s,n) ((x)>>(n))|((x)<<((s)-(n)))

extern uint8_t sndbuf[SOCKET_SEND_BUFFER_LENGTH_MAX];

extern unsigned char debug_on;
int sdk_port_printf(const char *fmt,...);
#define sdk_printf(fmt,arg...) do{if(debug_on){sdk_port_printf(fmt,##arg);}}while(0)



#endif

